// pages/camp/camp.js
var WxParse = require('../../wxParse/wxParse.js');
Page({

  /**
   * 页面的初始数据
   */
  data: {
    camp:'',
  },

  /**
   * 生命周期函数--监听页面加载
   */
  onLoad: function (options) {
    this.setData({
      tel: wx.getStorageSync('phoneNumber')
    })
    var that=this;
    wx.showLoading({
      title: '加载中',
    })
    wx.request({
      url: 'https://miniapp.odeman.com/summercamp/camp.php?areaid=' + wx.getStorageSync('areaid'),
      header: {
        'Content-Type': 'application/json'
      },
      success:function(res){
        wx.hideLoading()
        that.setData({ camp: res.data, content: res.data.content})
        var content = that.data.content;
        WxParse.wxParse('content', 'html', content, that, 5);
      }
    })
  },

 
})